package com.lzx.orderserver.model;

import com.fasterxml.jackson.annotation.JsonSubTypes;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.fasterxml.jackson.databind.annotation.JsonTypeIdResolver;
import com.lzx.orderserver.config.JacksonTypeIdResolver;
import lombok.Data;

/**
 * @author wb.liuzhengxing
 * @version v1.0
 * @package com.lzx.commons.entity
 * @data 2022/8/25 16:36
 */
@Data
@JsonTypeInfo(use = JsonTypeInfo.Id.CUSTOM, include = JsonTypeInfo.As.EXISTING_PROPERTY, property = "type", visible = true)
//@JsonSubTypes({
//        @JsonSubTypes.Type(value = Device.class, name = "Device"),
//        @JsonSubTypes.Type(value = Account.class, name = "Account")
//})
@JsonTypeIdResolver(JacksonTypeIdResolver.class)
public class Borrow {
    private String id;

    private BorrowType type;

}
